<?php

class Validator_LoadProfile extends Validator_Default {
    private $db;
    public function __construct($db) {
        $this->db = $db;
    }

    public function isValid($obj) {
        return $this->isValidES($obj);
    }

	private function isValidES($obj) {
        $esValidator = new Validator_ES();
        if (!$esValidator->isValid($obj->ES)) {
            $this->error = $esValidator->error;
            return false;
        }
        return true;
    }
}
